package com.lekang.system.domain;

import java.math.BigDecimal;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.lekang.common.annotation.Excel;
import com.lekang.common.core.domain.BaseEntity;
import java.util.List;

/**
 * 房型设置对象 room_type
 *
 * @author ruoyi
 * @date 2025-10-13
 */
public class RoomType extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 编号（数据库字段） */
    private Long id;

    /** 房间图片（数据库字段） */
    @Excel(name = "房间图片")
    private String roomImage;

    /** 房间类型（数据库字段） */
    @Excel(name = "房间类型")
    private String roomType;

    /** 床位费用（数据库字段） */
    @Excel(name = "床位费用")
    private BigDecimal bedFee;

    /** 创建人（数据库字段） */
    @Excel(name = "创建人")
    private Long creator;

    /** 房型介绍（数据库字段） */
    @Excel(name = "房型介绍")
    private String roomDescription;

    /** 状态(0:禁用 1:启用)（数据库字段） */
    @Excel(name = "状态(0:禁用 1:启用)")
    private Long status;

    /** 逻辑删除（数据库字段） */
    @Excel(name = "逻辑删除")
    private Long isDeleted;

    /** 额外字段1（数据库字段） */
    @Excel(name = "额外字段1")
    private String extraField1;

    /** 额外字段2（数据库字段） */
    @Excel(name = "额外字段2")
    private String extraField2;

    // ===================== 内存级关联字段（无数据库对应字段）=====================
    /** 关联：当前房型归属的楼层（多对1） */
    private Floor floor;
    /** 关联：当前房型下的所有房间（1对多） */
    private List<Room> roomList;
    // =============================================================================

    // 原有getter/setter（略，保持不变）
    public Long getId() { return id; }
    public void setId(Long id) { this.id = id; }
    public String getRoomImage() { return roomImage; }
    public void setRoomImage(String roomImage) { this.roomImage = roomImage; }
    public String getRoomType() { return roomType; }
    public void setRoomType(String roomType) { this.roomType = roomType; }
    public BigDecimal getBedFee() { return bedFee; }
    public void setBedFee(BigDecimal bedFee) { this.bedFee = bedFee; }
    public Long getCreator() { return creator; }
    public void setCreator(Long creator) { this.creator = creator; }
    public String getRoomDescription() { return roomDescription; }
    public void setRoomDescription(String roomDescription) { this.roomDescription = roomDescription; }
    public Long getStatus() { return status; }
    public void setStatus(Long status) { this.status = status; }
    public Long getIsDeleted() { return isDeleted; }
    public void setIsDeleted(Long isDeleted) { this.isDeleted = isDeleted; }
    public String getExtraField1() { return extraField1; }
    public void setExtraField1(String extraField1) { this.extraField1 = extraField1; }
    public String getExtraField2() { return extraField2; }
    public void setExtraField2(String extraField2) { this.extraField2 = extraField2; }

    // ===================== 关联字段的getter/setter =====================
    public Floor getFloor() { return floor; }
    public void setFloor(Floor floor) { this.floor = floor; }
    public List<Room> getRoomList() { return roomList; }
    public void setRoomList(List<Room> roomList) { this.roomList = roomList; }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("roomImage", getRoomImage())
                .append("roomType", getRoomType())
                .append("bedFee", getBedFee())
                .append("creator", getCreator())
                .append("roomDescription", getRoomDescription())
                .append("status", getStatus())
                .append("isDeleted", getIsDeleted())
                .append("extraField1", getExtraField1())
                .append("extraField2", getExtraField2())
                .append("floor", getFloor()) // 补充关联字段打印
                .append("roomList", getRoomList()) // 补充关联字段打印
                .toString();
    }
}